import { EntitySchema } from '@mikro-orm/core';

export class ImsYzdKpStorage {
  id!: number;
  type!: number;
  aliyun!: unknown;
  qiniu!: unknown;
  tengxun!: unknown;
  aliyunDb!: unknown;
  tengxunDb!: unknown;
  uniacid!: number;
  youpaiyun?: unknown;
}

export const ImsYzdKpStorageSchema = new EntitySchema({
  class: ImsYzdKpStorage,
  properties: {
    id: { primary: true, type: 'number' },
    type: { type: 'number', index: 'type' },
    aliyun: { type: 'unknown', columnType: 'longtext' },
    qiniu: { type: 'unknown', columnType: 'longtext' },
    tengxun: { type: 'unknown', columnType: 'longtext' },
    aliyunDb: { type: 'unknown', columnType: 'longtext' },
    tengxunDb: { type: 'unknown', columnType: 'longtext' },
    uniacid: { type: 'number', index: 'uniacid' },
    youpaiyun: { type: 'unknown', columnType: 'longtext', nullable: true },
  },
});
